A5Storage::DataContainer CopyContentsTo Method

Syntax

.CopyContentsTo as L (TargetContainer as A5Storage::DataContainer)

Arguments

TargetContainerA5Storage::DataContainer

The container to copy objects to.

Returns

ResultLogical

Returns .T. if the operation succeeds, otherwise .F. (see .CallResult for additional error information.)

Description

Copies all items to another container. Any existing items in the destination container will be replaced.

Example

dim Container as A5Storage::DataContainer = null_value()
dim TargetContainer as A5Storage::DataContainer = null_value()

CallResult = A5Storage::DataContainer::Open(Container, "Provider='Disk';Container='c:\A5Webroot\logs';")

? CallResult.Success
= .T.

CallResult = A5Storage::DataContainer::Open(TargetContainer, "Provider='Disk';Container='c:\A5Webroot\logs2';")

? CallResult.Success
= .T.

? Container.CopyContentsTo(TargetContainer)
= .T.